#include <stdio.h>
#include <time.h>
#include <sys/time.h>
#include <NDL.h>

// extern uint32_t NDL_GetTicks();
int main(){
    uint32_t temp,now;
    int i=0;
    temp = NDL_GetTicks();
    while (1)
    {
        // gettimeofday(&tv,&tz);
        now = NDL_GetTicks();
        if (now  > temp+ 500000)
        {
            temp = now;
            printf("Half a second passed and i = %d\n",i);
            i ++;
        }
        
        }
    return 0;

}